data-modified: 2024-11-29

W14-2: 12/27/2024

Libraries

Loading common packages

library(tidyverse)
library(haven) 
library(labelled) 
library(janitor) 
library(sjPlot)
library(psych)
set_theme(theme_minimal())

Setting up Data

Reading the prepped SPSS file from the preparation stage

data <- read_spss("Case 31 Data_efcu_Prepped.sav")

# generaet data dictionary
data |> 
  view_df()
Data frame: data
ID Name Label Values Value Labels
1 q3 Employees are Courteous 1
2
3
4
5
Strongly Disagree
Disagree
Uncertain
Agree
Strongly Agree
2 q4 Employees are helpful 1
2
3
4
5
Strongly Disagree
Disagree
Uncertain
Agree
Strongly Agree
3 q5 Employees are professional 1
2
3
4
5
Strongly Disagree
Disagree
Uncertain
Agree
Strongly Agree
4 q6 Employees are available 1
2
3
4
5
Strongly Disagree
Disagree
Uncertain
Agree
Strongly Agree
5 q7 savings rates 1
2
3
4
5
6
Very High
High
Average
Low
Very Low
No Opinion
6 q8 statement frequency 1
2
3
4
5
6
Very High
High
Average
Low
Very Low
No Opinion
7 q9 statement frequency 1
2
3
4
5
Too Often
Very Often
About Right
Not Often Enough
Never
8 q10 statement accuracy 1
2
3
4
Excellent
Good
Fair
Poor
9 q11 statement understandable 1
2
Yes
No
10 q12 Account Confidential 1
2
Yes
No
11 q13 regular share account 1
2
Aware and Have Used
Aware but Have Not Used
12 q14 special subaccounts 1
2
Aware and Have Used
Aware but Have Not Used
13 q15 Christmas club account 1
2
Aware and Have Used
Aware but Have Not Used
14 q16 IRA 1
2
Aware and Have Used
Aware but Have Not Used
15 q17 Master credit card 1
2
Aware and Have Used
Aware but Have Not Used
16 q18 signature loans 1
2
Aware and Have Used
Aware but Have Not Used
17 q19 new car loans 1
2
Aware and Have Used
Aware but Have Not Used
18 q20 late model car loans 1
2
Aware and Have Used
Aware but Have Not Used
19 q21 older model car loans 1
2
Aware and Have Used
Aware but Have Not Used
20 q22 household goods loans 1
2
Aware and Have Used
Aware but Have Not Used
21 q23 recreational loans 1
2
Aware and Have Used
Aware but Have Not Used
22 q24 share collateralized loan 1
2
Aware and Have Used
Aware but Have Not Used
23 q25 IRA loans 1
2
Aware and Have Used
Aware but Have Not Used
24 q26 line of credit loans 1
2
Aware and Have Used
Aware but Have Not Used
25 q27 currently have loan 1
2
Yes
No
26 q30 CU rates lower 1
2
3
4
5
Strongly Disagree
Disagree
Uncertain
Agree
Strongly Agree
27 q31 CU confidential 1
2
3
4
5
Strongly Disagree
Disagree
Uncertain
Agree
Strongly Agree
28 q32 CU is prompt 1
2
3
4
5
Strongly Disagree
Disagree
Uncertain
Agree
Strongly Agree
29 q33 CU meets needs of members 1
2
3
4
5
Strongly Disagree
Disagree
Uncertain
Agree
Strongly Agree
30 q34 CU loan applications simple 1
2
3
4
5
Strongly Disagree
Disagree
Uncertain
Agree
Strongly Agree
31 q37 overall rating 1
2
3
4
5
6
Excellent
Good
Average
Poor
Very Poor
No Opinion
32 overall_employee_performace range: 2.8-5.0
33 q38 headquarter 1
2
yes
no
34 employeeperformance range: 2.8-5.0
35 at_emp range: 2.8-5.0
36 q7r Savings rates 1
2
3
4
5
Very Low
Low
Average
High
Very High
37 q8r Fund borrowing rates 1
2
3
4
5
Very Low
Low
Average
High
Very High
38 q9r Statement Frequency 1
2
3
4
5
Never
Not Often Enough
About Right
Very Often
Too Often
39 q10r Statement Accuracy 1
2
3
4
Poor
Fair
Good
Excellent
40 q13r Regular share account 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
41 q14r Special subaccounts 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
42 q15r Christmas club account 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
43 q16r IRA 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
44 q17r Master credit card 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
45 q18r Signature loans 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
46 q19r New car loans 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
47 q20r Late model car loans 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
48 q21r Older model car loans 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
49 q22r Household goods loans 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
50 q23r Recreational loans 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
51 q24r Share collateralized loan 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
52 q25r IRA loans 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
53 q26r Line of credit loans 1
2
3
Unaware
Aware but Have Not Used
Aware and Have Used
54 q37r 1
2
3
4
5
Very Poor
Poor
Average
Good
Excellent

Research Questions and Hypotheses

Research Questions

R1: Why do people join the Credit Union?

R2: Why do members use other financial institutions when they need to borrow funds?

R3: What are the members’ attitudes and beliefs about the proficiencies of credit union employees?

R4: Are there any perceived differences on attitude towards employee proficiencies, awareness of services, and operational effectiveness between members who live in the area of the firm’s headquarters and members who live elsewhere?

R5: How well are the members aware of the services offered by the credit union?

R6: What are the members’ attitudes and beliefs about how effectively the credit union is operated?

Hypotheses

H1 - H3

H1: Members’ awareness of the regular share accounts will influence their opinions on the adequacy of financial services in meeting members’ needs.

H2: Members will not be different in their opinion on CU’s loan rate (Q8r) and the degree to which they agree that CU’s loan rate is lower than competitors (Q30).

H3a: There will be interaction effect between the current loan use and location of residence on adequacy of current financial services such that in headquarter area, members who have a loan will agree, more than those who don’t have, that financial services meet the members’ needs, while in outside headquarter area, loan status doesn’t influence adequacy of financial services in meeting member needs.

H3b: Test H2a controlling for the impact of attitudes toward employee proficiency.

H4 & H5

H4: Compared with the members who have a loan, those members who don’t have a loan currently with the Credit Union will feel that that CU charges them with higher rates, and that they will agree less with the statement that CU’s loan rates are lower than those offered by other institutions.

H5a: Member belief about CU keeps personal financial information confidential will positively influence the overall attitude toward credit union’s operational efficiency.

H5b: Loan application processing promptness will positively influence the overall attitude toward credit union’s operational efficiency.

H5c: Member satisfaction with level of financial services in meeting needs will positively influence the overall attitude toward credit union’s operational efficiency.

H5d: Loan application simplicity and easiness will positively influence the overall attitude toward credit union’s operational efficiency.

R1

R1: Why do people join the Credit Union?

  • Constructs and roles: reasons for why people join the credit uniion
  • Operationalization: q7r (Savings rates)
  • Scale:
    • 1-5 point, Likert-type scale
  • Statistics:
    • Descriptive statistics, followed by one sample t-test

Descriptive Statistics

data |> 
  count(q7r) |> 
  mutate(percent = n/sum(n))
# A tibble: 5 × 3
  q7r               n percent
  <dbl+lbl>     <int>   <dbl>
1  1 [Very Low]     1 0.00781
2  2 [Low]         12 0.0938 
3  3 [Average]     83 0.648  
4  4 [High]        22 0.172  
5 NA               10 0.0781 
describe(data$q7r)
   vars   n mean   sd median trimmed mad min max range  skew kurtosis   se
X1    1 118 3.07 0.57      3    3.07   0   1   4     3 -0.26     1.18 0.05
data |> 
  ggplot(aes(q7r)) +
  geom_histogram()

W15-1: 12/2/2024

one-sample t-test

data |> 
  t.test(q7r ~ 1, mu = 3, data = _)

    One Sample t-test

data:  q7r
t = 1.3016, df = 117, p-value = 0.1956
alternative hypothesis: true mean is not equal to 3
95 percent confidence interval:
 2.964639 3.170954
sample estimates:
mean of x 
 3.067797 

Insights about R1

  • The majority of the survey participants (65%) think that the savings rate the CU offers is average.
  • The sample mean is 3.07, which is not statistically different from 3 (“average”) (p > .10).

R2

R2: Why do members use other financial institutions when they need to borrow funds?

R3

R3: What are the members’ attitudes and beliefs about the proficiency of credit union employees?

  • Constructs and roles: Attitudes toward employee proficiencies
  • Operationalization:
    • q3, q4, q5, q6 –> at_emp
  • Scale: interval scale: 1-5 point, Likert-type scale
  • Statistics:
    • Descriptive statistics
    • Reliabilty/factor analysis,
    • one-sample t-test

Descriptive Statistics

describe(data$at_emp)
   vars   n mean   sd median trimmed  mad  min max range  skew kurtosis   se
X1    1 128 4.21 0.59      4    4.25 0.74 2.75   5  2.25 -0.32    -0.69 0.05

Histogram

data |> 
  ggplot(aes(at_emp)) +
  geom_histogram(binwidth = 0.5, color = "black", fill = "lightblue") +
  geom_vline(aes(xintercept = mean(at_emp, na.rm = TRUE)),
             color = "red", linetype = "dashed", size = 1) +
  geom_text(aes(x = mean(at_emp, na.rm = TRUE), y = 30, 
                label = paste0("Mean = ", round(mean(at_emp), 2))),
            color = "red", angle = 90, vjust = -0.5, hjust = 2.2) +
  labs(title = "Histogram of Employee Proficiencies with Mean Line",
       x = "Employee Prociency",
       y = "Count") +
  scale_x_continuous(expand = c(0,0), limits = c(0, NA))

Reliability/factor analysis

  • We already looked at reliability and unidimensionality.
  • The four items are highly representative of the latent construct.
  • Therefore, we created a compositie index and use it

one-sample t-test

data |> 
  t.test(at_emp ~ 1, mu = 4, data = _)

    One Sample t-test

data:  at_emp
t = 3.9063, df = 127, p-value = 0.0001515
alternative hypothesis: true mean is not equal to 4
95 percent confidence interval:
 4.101192 4.308965
sample estimates:
mean of x 
 4.205078 

Summary insights about R3

Participants perceived Employee proficiency is 4.21 on average out of 5.0 and is greater than 4.0 (“Agree”)

R4

R4: Are there any perceived differences on (a) attitude towards employee proficiencies, (b) awareness of services, and (c) operational effectiveness between members who live in the area of the firm’s headquarters and members who live elsewhere?

R4a Data Analysis Overview

  • R4a: Are there any perceived differences on attitude towards employee proficiencies between members who live in the area of the firm’s headquarters and members who live elsewhere?
- Constructs and roles: 
  - Member residence: IV
  - Attitudes toward employee proficiency: DV 
- Operationalization: 
  - q38
  - at_emp
- Scale: 
  - Nominal scale: 
  - interval scale: 1-5 point, Likert-type scale
- Statistics: 
  - Descriptive statistics, followed by independent samples t-test

Descriptives

Boxplot

data |> 
  mutate(q38 = haven::as_factor(q38)) |> 
  ggplot(aes(q38, at_emp, fill = q38)) +
  geom_boxplot() +
  labs(x = "Live in HQ Area",
       y = "Attitudes toward Employee Proficiency",
       title = "Does Employee Proficiency differ by where customers live?") +
  theme(legend.position = "none")

Barplot

data |> 
  mutate(q38 = haven::as_factor(q38)) |> 
  group_by(q38) |> 
  summarize(mean = mean(at_emp, na.rm = TRUE)) |> 
  ggplot(aes(q38, mean, fill = q38)) +
  geom_col() +
  labs(x = "Live in HQ Area",
       y = "Attitudes toward Employee Proficiency",
       title = "Does Employee Proficiency differ by where customers live?") +
  theme(legend.position = "none")

Two independent sample t-test

# check for equal variance
library(car)

data |> 
  mutate(q38 = haven::as_factor(q38)) |> 
  leveneTest(at_emp ~ q38, data = _)
Levene's Test for Homogeneity of Variance (center = median)
       Df F value Pr(>F)
group   1   0.041 0.8399
      126               
data |> 
  mutate(q38 = haven::as_factor(q38)) |> 
  var.test(at_emp ~ q38, data = _)

    F test to compare two variances

data:  at_emp by q38
F = 0.89996, num df = 56, denom df = 70, p-value = 0.6864
alternative hypothesis: true ratio of variances is not equal to 1
95 percent confidence interval:
 0.548864 1.496643
sample estimates:
ratio of variances 
         0.8999608 
# t.test: assuming var are equal
data |> 
  t.test(at_emp ~ q38, data = _, var.equal = TRUE) 

    Two Sample t-test

data:  at_emp by q38
t = 1.2941, df = 126, p-value = 0.198
alternative hypothesis: true difference in means between group 1 and group 2 is not equal to 0
95 percent confidence interval:
 -0.0721542  0.3448253
sample estimates:
mean in group 1 mean in group 2 
       4.280702        4.144366 

Summary insights about H4a

The group mean value on employee proficiency for customers who live in HQ and those who live elsewhere are not statistically different.

Thus, we conclude that the location of customer residence is not associated with their perception of CU employee proficiency.

R4b Data Analysis Overview

  • R4b: Are there any perceived differences on awareness of services between members who live in the area of the firm’s headquarters and members who live elsewhere?
- Constructs and roles: 
  - Member residence: IV
  - service awareness: DV
- Operationalization: 
  - q38
  - q13r - q26r
- Scale: 
  - Nominal scale: 
  - Ordianal scale
- Statistics: 
  - Two-way cross-tab, followed by Chi-square independence test

Cross-tab and Chi-square

q13r by q38

data <- data |> 
  mutate(q13r = haven::as_factor(q13r),
         q38 = haven::as_factor(q38))

# cross-tabulation: count
table(data$q13r, data$q38)
                         
                          yes no
  Unaware                  34 49
  Aware but Have Not Used  16 16
  Aware and Have Used       7  6
# cross-tab: %
table(data$q13r, data$q38) |> 
  prop.table(margin = 2) * 100 
                         
                                yes        no
  Unaware                 59.649123 69.014085
  Aware but Have Not Used 28.070175 22.535211
  Aware and Have Used     12.280702  8.450704
# Chi-square test of independence
table(data$q13r, data$q38) |>
  chisq.test() 

    Pearson's Chi-squared test

data:  table(data$q13r, data$q38)
X-squared = 1.2717, df = 2, p-value = 0.5295
table(data$q38, data$q13r) |> 
  mosaicplot(main = "Awareness of Regular share account by Residence", 
             color = TRUE, las = 1 )

q14r by q38

data <- data |> 
  mutate(q14r = haven::as_factor(q14r))

# cross-tabulation: count
table(data$q14r, data$q38)
                         
                          yes no
  Unaware                  22 24
  Aware but Have Not Used  31 39
  Aware and Have Used       4  8
# cross-tab: %
table(data$q14r, data$q38) |> 
  prop.table(margin = 2) * 100 
                         
                                yes        no
  Unaware                 38.596491 33.802817
  Aware but Have Not Used 54.385965 54.929577
  Aware and Have Used      7.017544 11.267606
# Chi-square test of independence
table(data$q14r, data$q38) |>
  chisq.test() 

    Pearson's Chi-squared test

data:  table(data$q14r, data$q38)
X-squared = 0.81305, df = 2, p-value = 0.666
table(data$q38, data$q14r) |> 
  mosaicplot(main = "Awareness of Special Sub accounts by Residence", 
             color = TRUE, las = 1 )

q15r by q38

data <- data |> 
  mutate(q15r = haven::as_factor(q15r))

# cross-tabulation: count
table(data$q15r, data$q38)
                         
                          yes no
  Unaware                  17 25
  Aware but Have Not Used  35 40
  Aware and Have Used       5  6
# cross-tab: %
table(data$q15r, data$q38) |> 
  prop.table(margin = 2) * 100 
                         
                                yes        no
  Unaware                 29.824561 35.211268
  Aware but Have Not Used 61.403509 56.338028
  Aware and Have Used      8.771930  8.450704
# Chi-square test of independence
table(data$q15r, data$q38) |>
  chisq.test() 

    Pearson's Chi-squared test

data:  table(data$q15r, data$q38)
X-squared = 0.42185, df = 2, p-value = 0.8098
table(data$q38, data$q15r) |> 
  mosaicplot(main = "Awareness of Christmas club account by Residence", 
             color = TRUE, las = 1 )

Further cleaning

data <- data |> 
  mutate(q13r = haven::as_factor(q13r),
         q14r = haven::as_factor(q14r),
         q15r = haven::as_factor(q15r),
         q16r = haven::as_factor(q16r),
         q17r = haven::as_factor(q17r),
         q18r = haven::as_factor(q18r),
         q19r = haven::as_factor(q19r),
         q20r = haven::as_factor(q20r),
         q21r = haven::as_factor(q21r),
         q22r = haven::as_factor(q22r),
         q23r = haven::as_factor(q23r),
         q24r = haven::as_factor(q24r),
         q25r = haven::as_factor(q25r),
         q26r = haven::as_factor(q26r)
         )

R4c Data Analysis Overview

  • R4c: Are there any perceived differences on operational effectiveness between members who live in the area of the firm’s headquarters and members who live elsewhere?
- Constructs and roles: 
  - Member residence: IV
  - operatoinal effectiveness: DV
- Operationalization: 
  - q38
  - q9r, q10r, 
  - q11-q12r, 
  - q31-q34, 
  - q37r
- Scale: 
  - Nominal scale
  - interval scales
  - Nominal
  - interval
  - interval
- Statistics: D
  - Descriptive statistics, followed by
    - 2-groups t-test 
    - Ch-square independence test
    - 2-groups t-test
    - 2-groups t-test

R5

R5: How well are the members aware of the services offered by the credit union?

  • Constructs and roles:
    • Awareness of services:
  • Operationalization:
    • q13r-q26r
  • Scale:
    • Ordinal scale:
  • Statistics:
    • Chi-square goodness-of-fit test

q13r

p = c(1/3, 1/3, 1/3)
table(data$q13r) |> 
  chisq.test(p = p)

    Chi-squared test for given probabilities

data:  table(data$q13r)
X-squared = 61.422, df = 2, p-value = 4.596e-14

More efficient coding with map()

# data

awareness_long <- data |> 
  select(q13r:q26r) |> 
  pivot_longer(cols = everything(),
               names_to = "services",
               values_to = "awareness")
awareness_long
# A tibble: 1,792 × 2
   services awareness              
   <chr>    <fct>                  
 1 q13r     Aware and Have Used    
 2 q14r     Aware but Have Not Used
 3 q15r     Aware but Have Not Used
 4 q16r     Aware but Have Not Used
 5 q17r     Aware but Have Not Used
 6 q18r     Aware but Have Not Used
 7 q19r     Aware and Have Used    
 8 q20r     Aware and Have Used    
 9 q21r     Aware but Have Not Used
10 q22r     Aware but Have Not Used
# ℹ 1,782 more rows
# Expected proportions (e.g., equal distribution across levels)
exp_p <- c(`Unaware` = 1/3, 
           `Aware but Have Not Used` = 1/3, 
           `Aware and Have Used` = 1/3) 

# Perform chi-square goodness of fit for each product
awareness_long |> 
  group_by(services) |> 
  count(awareness) |> 
  complete(awareness = names(exp_p), fill = list(n = 0)) |> # tidyr
  group_by(services) |> 
  summarise(
    chisq_test = list(chisq.test(
      x = n,
      p = exp_p[levels(factor(awareness))]
  ))
  ) |> 
  mutate(tidy_results = map(chisq_test, broom::tidy)) |> 
  unnest(tidy_results)
# A tibble: 14 × 6
   services chisq_test statistic  p.value parameter method                      
   <chr>    <list>         <dbl>    <dbl>     <dbl> <chr>                       
 1 q13r     <htest>         61.4 4.60e-14         2 Chi-squared test for given …
 2 q14r     <htest>         39.8 2.26e- 9         2 Chi-squared test for given …
 3 q15r     <htest>         48.0 3.75e-11         2 Chi-squared test for given …
 4 q16r     <htest>         16.4 2.72e- 4         2 Chi-squared test for given …
 5 q17r     <htest>         26.9 1.43e- 6         2 Chi-squared test for given …
 6 q18r     <htest>        135.  6.07e-30         2 Chi-squared test for given …
 7 q19r     <htest>        116.  7.16e-26         2 Chi-squared test for given …
 8 q20r     <htest>        124.  1.30e-27         2 Chi-squared test for given …
 9 q21r     <htest>         62.4 2.88e-14         2 Chi-squared test for given …
10 q22r     <htest>         56.9 4.36e-13         2 Chi-squared test for given …
11 q23r     <htest>         31.2 1.65e- 7         2 Chi-squared test for given …
12 q24r     <htest>         59.8 1.02e-13         2 Chi-squared test for given …
13 q25r     <htest>         64.6 9.56e-15         2 Chi-squared test for given …
14 q26r     <htest>         76   3.14e-17         2 Chi-squared test for given …

R6

R6: What are the members’ attitudes and beliefs about how effectively the credit union is operated?

H1

H1: Members’ awareness of the regular share accounts will influence their opinions on the adequacy of financial services in meeting members’ needs.

H2

H2: Members will not be different in their opinion on CU’s loan rate (Q8r) and the degree to which they agree that CU’s loan rate is lower than competitors (Q30).

H3a

H3a: There will be interaction effect between the current loan use and location of residence on adequacy of current financial services such that in headquarter area, members who have a loan will agree, more than those who don’t have, that financial services meet the members’ needs, while in outside headquarter area, loan status doesn’t influence adequacy of financial services in meeting member needs.

H3b

H3b: Test H2a controlling for the impact of attitudes toward employee proficiency.